<?php
use kartik\detail\DetailView;
use yii\helpers\Url;
use common\libs\Constants;
use backend\models\activeRecords\TPay;

/* @var $this View */
/* @var $model TPay */

$this->title = $model->pay_id;
$this->params['breadcrumbs'][] = ['label' => Yii::t('app', 'Tpays'), 'url' => ['index']];
$this->params['breadcrumbs'][] = $this->title;

$attributes = [
        [
            'group' => true,
            'label' => '基础信息',
            'rowOptions' => ['class' => 'info']
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_order_no'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_order_no_cooperate'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_type'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_mode_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_state'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_user'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_tel'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_game_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_server_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_game_user'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_game_role'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_money'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_money_with_rate'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_time'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_ip'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'card_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'coupon_id'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_game_name'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'pay_server_name'],

            ]
        ],
                [
            'columns' => [

                                        ['attribute' => 'remark'],

            ]
        ],
        ];


echo DetailView::widget([
    'model' => $model,
    'panel' => [
        'heading' => 'tpay # ' . $model->pay_id,
        'type' => DetailView::TYPE_PRIMARY,
    ],
    'attributes' => $attributes,
    'labelColOptions' => ['class' => 'col-sm-2'],
    'valueColOptions' => ['class' => 'col-sm-6'],
    'deleteOptions' => [
        'url' => Url::to(['delete', 'id' => $model->pay_id])
    ],
    'formOptions' => [
        'id' => 'view-form',
        'options' => [
            'enctype' => 'multipart/form-data'
        ],
        'enableAjaxValidation' => true,
        'validationUrl' => Url::toRoute(['validate-form'])
    ]
]);